Coalition Formation Game for Cost-Efficient Multiparty Payment Channel in Payment Channel Networks

Blockchain has introduced a new era for online payment services and its economy with tamper-proof cryptocurrencies. However, blockchain, which is based on global peer-to-peer networks, has its limitations due to payment delays from global consensus and transaction costs for maintenance. Thus, payment channel networks (PCN) have been proposed as one of the most promising off-chain solutions, allowing users to pay directly through payment channels (PC), with minimal blockchain involvement. However, payment delays and cost problems still exist, especially given the large size of the PCN. This study proposes a multiparty payment channel (MPC) that enables multiple users to join the same PC and exchange payment transactions, compared to the legacy PC. To avoid a consensus procedure among users in the PC, we introduce sequential and parallel updates for the PC status. Since increasing the MPC size limits the advantages in terms of the delay and cost, we propose a distributed coalition formation algorithm to form the MPC group, in which each user has the choice to join or leave the group. Simulations show that the proposed algorithm establishes MPCs successfully, considering the trade-off between the payoff gain and the MPC delay cost.


Introduction
With the many successes of cryptocurrency, the blockchain has been confirmed as a tamper-proof ledger operating in autonomous peer-to-peer (P2P) networks. However, the blockchain suffers from inherent scalability problems as the number of nodes and transactions grows rapidly. The consensus algorithms, such as proof of work for Bitcoin [1] and Ethereum [2], require excessive time to order transactions chronologically and synchronize them globally. Although many consensus algorithms, termed PoX (e.g., Proof of Stake [3], Delegated Proof of Stake [4], Proof of Validation [5], Proof of Elapsed time [6]), have been proposed to improve the performance in terms of transactions per second, it is still critical to maintain a unique chain agreed by globally distributed nodes.
Instead, multiple leading chains can be used to deal with transactions in parallel, for which separate committees of these chains decide the final status of their chain independently, called blockchain sharding (e.g., RScoin [7], omniLedger [8], or rapidChain [9]). Similarly, parasite chains (called side chains) plugged into the main chain can be used to improve scalability, e.g., Plasma [10]. However, such multiple-chain approaches require periodic mutual verification for integrity checks. In contrast to the legacy blockchain, a directed acyclic graph (DAG)-based blockchain (e.g., IOTA [11], Nxt, ByteBall, and coDAG [12][13][14]) allows forking, which enables asynchronous updates within multiple side chains, converging in a specific direction. It is vulnerable to double spending by split attacks or long parasite chaining and still relies on a global consensus.
In this paper, we focus on the L2 protocol for the blockchain network, called an "off-chain" protocol [15], by which two users can create a local ledger ("payment channel (PC)") for transactions between them and pay each other directly by updating the balance information in the PC [16]. Therefore, the off-chain technique completes transactions faster than the blockchain without a consensus and fee.
The PC is expanded to payment networks for indirect payment, called payment channel networks (PCN), because all users cannot have direct PCs to each other. A user can pay someone indirectly through multiple PCs of unknown intermediary users and payment service providers (PSP), such as multihop routing in ad hoc networks. Such multihop payment is a path-based transaction (PBT) in the PCN. This PCN is a promising technology to improve the scalability and efficiency of the main blockchain. Several offchain payment networks have been proposed and developed for cryptocurrencies, such as the Lightning network [17] for Bitcoin, Raiden network [18] for Ethereum, and Paymo [19] for Monero.
There have been many studies about the PCN. First, the PBT routing algorithm was explored, which is critical to protect privacy and maximize the PCN throughput. Flare [20], as the first routing protocol, finds a feasible transaction path in the PCN by mimicking a multihop ad hoc network protocol for the Lightning network. SilentWhispers [21] and SpeedMurmurs [22] introduced efficient decentralized routing algorithms for fast and private payment settlement in the PBT. VOUTE [23] followed, enhancing the efficiency of the landmark routing of SilentWhispers. Meanwhile, Rayo and Fulgor [24] provided privacy and concurrency mechanisms in the PBT. Several studies proposed ideas to improve the PCN performance, limited by the channel deposit amount and PBT length. Spider [25,26] and Flash [27] introduced atomic multipath payments, which increased the PCN throughput by splitting a large PBT flow into many small flows. A redundant and secure balance was planned [28,29] and transaction forwarding was scheduled [30] by the mathematical optimization model, assuming that the payment demands are known. Some studies investigated the economic aspects of the PCN [31,32]. Cheapay [33] and payGo [34] found an economic payment path in terms of low fees of PSPs.
In this study, we focus on the two major challenges of the PCN as below.
• Unbalanced collateral: The PC user balance varies dynamically with payment flows. Accordingly, asymmetric payment flows cause unbalanced collateral and balance depletion, which stops payment for upcoming PBTs. • Collateral cost: A PSP must lock the collateral amount for each PBT to prevent double spending. This collateral cost increases with the number of PBTs and their delays.
First, the exhaustion of the balance due to the biased payment direction has been solved by an artificial opposite PBT flow. Revive [35] and Circle [36] search the circular payment flows to rebalance the channel. However, this approach assumes mutual trust among users on the circular path and has difficulty in finding the circular path without causing an imbalance in other channels. Chen et al. [37] introduced a MPC for rebalance that provides the order of transactions among multiple PCs within a group. This work does not consider utility for MPC formation; accordingly, a given MPC topology limits rebalance. Second, there are several L3 approaches to rebalance deposits among existing L2 PCs. Burchert et al. [38] introduced the channel factory concept that reassigns deposit tokens to a specific pairwise channel dynamically based on agreement by n-party users. Dziembowski et al. [39,40] proposed the virtual channel concept that creates a direct virtual channel between two users linked by multiple PCs. Following this, more studies [41,42] improved upon the virtual channel concept. However, the security of these concepts relies on the behavior of underlying PSPs.
This study proposes a multiparty payment channel (MPC) only using the L2 protocol that reduces the collateral cost of the PSP and the probability of deposit imbalance. For instance, if four users with pairwise channels are grouped into an MPC, the collateral cost decreases by one third, while the probability of incoming PBT flows increases by three. The MPC adopts slotted payment for sequential updates of an off-chain state. However, the utility of a grand coalition does not increase additively due to the delay cost in underlying networks. Because the turnaround delay for individual payment slots increases proportionally to the MPC size, multiple MPC coalitions must be created regionally to maximize their utility in the PCN. We propose a distributed algorithm based on the switching operation for each PSP in such a coalition formation game, which permits the PCN to converge to the Nash equilibrium of MPC partitions. We simulate the user payment flows in random social networks and investigate the performance of the MPC formation algorithm with varying turnaround delays and cost parameters. Experimental results show that the proposed algorithm forms MPC coalitions stably and improves the PCN utility consistently by limiting the individual MPC size according to the incidental cost.
In summary, our key contributions in this study are highlighted below.
• A multiparty payment channel is designed above Layer 2 in the blockchain network. • Expected threats to the MPC are discussed, such as double spending and the Sybil attack. • A mathematical model is established to derive the optimal MPC size. • A distributed MPC formation algorithm is proposed for this coalition formation game.
The rest of this study is organized as follows. First, the background of the PC and network is briefly reviewed in Section 3. We introduce the MPC algorithm and its protocol design with smart contracts in Section 4. Section 5 describes a distributed MPC formation algorithm that maximizes PSP utility in the PCN. In Section 6, we evaluate the performance of the coalition formation algorithm and discuss the experimental results. We conclude this paper in Section 7.

Related Works
The payment channel imbalance and depletion problem is a well-known problem and has been studied for the past several years. In this section, we introduce details of these studies and compare them as in Table 1. Since the channel depletion is caused by imbalanced payment flows in the PCN, many researchers solved it by equalizing the PBT flows. As a seminal work, Revive [35] proposed an artificial opposite PBT flow to achieve balance between bi-directional PBT flows within a payment channel. For this, a user has to find a circular path for the rebalancing, in which each user probably suffers from imbalanced flows. Revive has a critical limitation in that all users along the circular path should trust each other; otherwise, there is no mechanism to receive payback when a certain party denies pay forwarding. For this, Circle [36] was recently proposed, which creates a smart contract to prevent the misbehavior of these participants in the circular payment.
In [38], a multiparty channel was proposed for the first time for the Bitcoin micropayment channel. The authors created a middle layer between the Bitcoin and micropayment channel layers, called a channel factory, that replaces a transaction with a shared lock on the channel deposit whenever a rebalance among the micro-payment channels is required. However, it is still costly for relocation transactions due to the nature of the Bitcoin network and relies on complicated data structures of timelocked transactions for state consensus. Perun, as a virtual payment channel over the L2 protocol, was proposed in [39,40]. Perun is a payment hub that has direct channels with several parties without intermediary users. The authors extended Perun for a general multiparty channel [41]. Perun can be easily realized by smart contracts, compared to previous studies. However, it also assumes that the intermediary users along the virtual channel are trusted or can be punished for misbehavior by the smart contract. Accordingly, Perun can reuse the deposit for the virtual channel but it requires smart contracting with a delay. Meanwhile, [42,43] extended Perun to the Bitcoin network as a lightweight virtual payment channel, only requiring timelocks and multi-signatures.
Recently, the MPC concept based on multiple PCs was introduced in [37], which is designed only for a fixed PCN topology, in contrast to our proposal. As the MPC demands consensus on every transaction to all parties and schedules its individual PCs proportionally to balance, the transaction latency can increase exponentially according to the number of users. However, MPC formation is not discussed for such a scalability problem.

Background
In this section, we introduce the PC and PCN briefly as a background and discuss channel imbalance as a key challenge of the PCN. The PC is a logical connection between two users who exchange messages for payment, improving the transaction scalability due to the absence of blockchain involvement. For this, the users open the PC, a type of escrow account, by depositing an amount using a smart contract, executing over the public Ethereum network, and the balance amount cannot be withdrawn without the agreement of the other party; there is an alternative approach for the Bitcoin network. After this, these two users pay each other safely within their own balance.
The PCs can constitute a network, a PCN, as a communication link through the Internet, in which users are able to pay someone remotely, without a direct PC. Such a remote payment, called a PBT, can be relayed through multiple intermediary PCs of unknown users along a payment path that is discovered by a routing protocol for the PCN [34]. Consequently, the PBT mechanism of the PCN can solve the scalability problem expected with countless users in the off-chain model. In the following subsections, more detailed procedures are explained.

Direct Payment Channel
The PC is a local ledger recording transactions between two users, in which they can update the ledger without blockchain intervention. In other words, consensus on the channel state is made only by the two users who agree with the new balance of the PC; a user verifies the signature of the counterparty on the new transaction and adds their signature.
The main blockchain governs only the opening or closing of the PC. To open the PC, two users deposit an amount in an escrow account through the smart contract to prevent double spending. If he disagrees on the PC state, the user ignores it and asks to close the channel through the smart contract. Then, the smart contract returns the amount based on the last PC state. Since these two procedures require transaction fees in the main blockchain, they will not invoke the unnecessary closing procedure.
This study explains the MPC mechanism using a bidirectional PC created by the smart contract in the Ethereum network. Any other PCs, such as a micro-PC for Bitcoin [44], can also be used for the MPC.

Multihop Payment Channel Network
It is costly and impractical for a user to create a PC for a new payee every time. The PCN supports indirect payment through multiple PCs based on the conditional balance proof (BP) concept of Ethereum that guarantees atomic payment between a payer and payee, which works similarly with the hashed timelocked contract of the Lightning network [17]. Details of this protocol are described in Figure 1.  For the PBT procedure from the user A to C, the user A sends a conditional BP, including a new channel balance with his signature, to the user B, preventing double spending by A. The conditional BP can be valid only when the receiver secures a pre-image of the hashed secret #S included in the BP. The receiver can reimburse the amount of the conditional BP from a counterparty or smart contract in the main chain if the counterparty does not unlock it after receiving the S until the deadline. The smart contract verifies the pre-image S and hash value, #S = SHA256 (S), for the balance update, returns the amount based on the final balance, and closes the PC. Accordingly, rational users behave honestly to keep the channels open for future transactions or monetary incentives from PBT relaying [34]. The receiver can try to request the unlock repeatedly from the counterparty, rather than the arbitration of a smart contract for dispute resolution.
The Raiden network [18] supports concurrent PBTs (i.e., PBT flow) with a Merkle tree of information of the in-flight conditional payments, such as the amount, a lock timer, a secret hash, the public key of a payer, etc. Concurrency is also supported in the Bitcoincompatible PCN [45]. To avoid a balance deficiency due to many in-flight PBTs, each conditional payment has a lock timer for a deadline that prevents collateral from being locked infinitely. Expired conditional BPs are discarded, and the corresponding amount can be used for the next payment if no PSP along the payment path unlocks before the PBT is canceled. However, finding an optimal lock time is challenging based on previous PBTs; the tight duration can cause frequent payment failures and channel closures, while a loose duration increases the collateral costs.

Payment Channel Imbalance
Asymmetric PBT flows can cause a channel imbalance that induces a balance deficiency and degrades the payment throughput in the PCN. Figure 2 depicts the dynamics of tokens at three channels with two asymmetric PBT flows F1 and F2. The PBT F1 moves two tokens toward the counterparty every second, while F2 moves backward only one token. This asymmetric PBT flow eventually causes balance depletion for one of the channel users. We investigate the PCN performance with the imbalanced PBT flows as in Figure 2 using a discrete-time PCN simulator [34]. For the experiment, unlimited tokens are given to the payers, A and D, while the other two PSPs, B and C, have fixed deposits. Each payment amount of the PBTs is configured as 50% of the initial channel deposit. The message propagation and processing delay follow an exponential distribution of 10 and 1 ms, respectively. The time lock is set as 3 s for each transaction. Figure 3 shows the success and failure probability of payment, which depends on the balance of the PBT flows. Asymmetric flows by different payment intervals cause significant transaction failures significantly below 1 s due to a higher PBT rate of F1. Meanwhile, symmetric flows with 1 s have no failed transactions. The number of successful transactions as throughput is limited by a flow with a lower PBT rate, which decreases as the F1 rate diminishes, as shown in the figure.  Consequently, the PC performance relies on the channel balance, which is dynamically changed with the PBT flows x ij . Furthermore, the channel deposits should be larger than the amount of each PBT, even for balanced PBT flows. We propose an MPC solution that maximizes the throughput and minimizes payment delay under unbalanced PBT flows and limited channel deposits.

Multiparty Payment Channel
In this study, we propose a novel MPC that consists of multiple PSPs in distributed PCNs. Each PSP user can have multiple PCs to other PSPs only with a single deposit, which increases the collateral efficiency compared to the conventional PCN. For instance, the MPC architecture enables the collateral cost of the legacy PC to increase quadratically I 2 C with users I and channel deposit C, and linearly IC in the MPC. Additionally, the MPC can mitigate channel imbalance or depletion via asymmetric PBT flows since an MPC user has more incoming PBT flows from N-1 peers.
In contrast to previous MPC approaches based on the existing PCs, our MPC is based on the consensus of all PSP members for a ledger update. The MPC can have multiple transactions concurrently occurring between two particular parties, which needs to be ultimately acknowledged by all members. Accordingly, the update order should be given to avoid ambiguity of the MPC state and prevent subsequent misbehavior such as double spending. For this, we assign a numerical identifier to each virtual sub-channel between two PSPs, which provides order information of the MPC state and traceability in the MPC balance. We explain the details of the MPC mechanism from channel creation to channel state update in the following subsections, with the symbols in Table 2.

MPC Creation
As addressed in our previous study [34], where a PC is created by an L2 protocol and smart contract running in an Ethereum virtual machine, the MPC can be created similarly by multiple users. Users execute individually a registration function to open a channel with information parameters, e.g., an initial deposit, an account address, a host IP address, etc. To close the channel, a close function is called with a final channel state and the signatures of all users, which returns the amount to each user based on the final channel balance. The final MPC state is determined by the transaction with the highest round count, which increases for every transaction.

MPC Consensus Algorithm
In contrast to the legacy PC, in which interest is a conflict between two users, the MPC needs a consensus algorithm as users can collude in their own interests against other participants. Majority-based consensus algorithms for the public blockchain are infeasible since securing more than 50% users in such a small group is easy. For the small-sized private blockchain, Byzantine Fault-Tolerant (BFT) protocols, such as Practical BFT (PBFT) [46][47][48], are popularly considered. However, this permission-based approach in which all users are admitted by a certificate authority is inapplicable for the MPC, which is a permissionless off-chain network, as with the legacy PC.
The MPC consensus algorithm has to resolve the following two challenges: • State update of the MPC, from M(t) to M(t + 1). • Transaction serialization in the local chain of the MPC.
All users should form a consensus for the MPC state update by signing on a new transaction that changes the channel state. This consensus procedure requires heavy peer-to-peer communication that causes a considerable delay, especially with many MPC members, N.
A unique round count should be assigned to each transaction sequentially for serialization. Simultaneous payments fork the local chain with multiple transactions having the exact round count. Unfortunately, the MPC cannot resolve the dependency between concurrent transactions based on the majority. Therefore, we introduce a time-slotted sub-channel or sub-PC (SPC) concept for the MPC. At each time slot denoted by the round count t, only two MPC users, called SPC users, can create a new transaction with the given round count. Once the users of an SPC receive a local chain from anyone of a previous SPC, they must verify the blocks in terms of balance and a round count signed by the previous SPC users to update the MPC state. After this, they add a new block for their transaction to the local chain and send it to the following SPC users. For example, users A and B exchange their BPs (e.g., A: 100, B: 70), including the round count t = 0, which are signed by their private keys at v AB , which leads to the update of the MPC state as M(t = 0). One of the users, A or B, sends the local chain, including the new block, to either of the users B or D. Subsequently, the users B and D verify the MPC state M(t = 0) and follow the same procedure for a new state M(t = 1). In the event that the received block has incorrect balance or count information, the users can initiate a dispute process with a smart contract in the blockchain, eventually preventing forking and dishonest behavior such as double spending in the MPC.

Full Synchronization
The MPC state is updated immediately by broadcasting the new transaction block or using a central repository. The broadcast requires additionally a node discovery and routing protocol to build up a minimum spanning tree, while the repository can suffer from a single point of failure and congestion.

Partial Synchronization
For scalability, the MPC state can be partially synchronized along the order of the SPCs, which allows each user to update the global view only at their turn. For this, a user of an SPC v ij (t) sends the updated local chain only to users of the next SPC v mn (t + 1), which can therefore reduce the communication overhead compared to full synchronization.
For partial synchronization, each SPC user verifies n previous SPC blocks, v ij (t − n, t), of the received local chain for the MPC state update if the last state that the user confirmed is v ij (t − n − 1). For example, in Figure 5, user B must confirm the current MPC state before trading with counterparty A at the T 6 . Since the balance of user A could be changed in the block of v AD at the T 5 , user B must acquire and verify the v AD (t = T 5 ) block. If the v AD (t = T 5 ) transaction is incorrect, user B can invoke a dispute procedure and close the MPC. Contrarily, user A does not need to update at T 6 because the last MPC state is already known at T 5 .
Therefore, the number of blocks to verify depends on the SPC schedule as below.
• Periodic SPC for minimum blocks: in fully connected PSPs that individually have N − 1 SPCs over total N(N − 1)/2, each PSP has its own SPC every N/2 round and the same number of blocks to verify. • Aperiodic SPC for minimum communication: as shown in Figure 5, SPCs can be linked by an anchoring node that can reduce the communication overhead for local chain propagation. According to the Euler trail algorithm, all SPCs can be visited without additional communication if the N is an odd number, and a single extra communication instance is needed otherwise. However, in the worst case, the maximum number of verification blocks can be V − N + 1. VDC  VAC  VCB  VAD  VAB   T0  T1  T2  T3  T4  T5  t=T6 S[t-|V|, t-1]  Figure 4. To verify the final MPC state, user A holds total V previous blocks at t = T 6 . Subsequently, the new update by v AB (t = T 6 ) removes the obsolete v AB (t = T 0 ).

VAB VBD
The aperiodic SPC probably has a serious update overhead with the propagation of previous n blocks if the MPC size, N, grows exponentially, even though each block is only around a hundred bytes, containing a round count (4 bytes), user accounts (20 bytes × 2), the BPs of two users (4 bytes × 2), and the two signatures of i, j of v ij (32 bytes × 2). In this study, we use the periodic SPC schedule in the following algorithms.
Algorithm 1 describes the update procedure in the MPC. An SPC user updates the MPC state sequentially along the order of blocks in the received chain unless the signatures are wrong or the balance sum differs from the previous state. Otherwise, the dispute procedure will be triggered by the user. During the dispute procedure, the smart contract settles the balances based on the final MPC state. Algorithm 2 shows the dispute resolution algorithm conducted by the smart contract. All participants upload their own V blocks of the last SPC cycle v ij (t), t ∈ [n − V, n − 1] before closing the channel, where the last round counts n can vary for each user. Subsequently, the smart contract orders receive blocks chronologically and verify each one to update the MPC state sequentially, as in Algorithm 1. In the end, the block with the highest round count finalizes the user balance.
, t m } 5: Instruction: 6: for t m ∈ [n, n + (N/2) ] do 7: if t m == γ v ij and We discuss the possible security threats in the MPC and their resolutions through the dispute algorithm.

•
Double spending: if a malicious user attempts to pay with the wrong BP information, it is detected by a counterparty based on previous blocks, which denies the proposed transaction. Although the counterparty accidentally signs the transaction of the double spending at T n , the smart contract can later detect the transaction that contradicts a previous T n−1 MPC state. • Sybil attack: if user B, C, or D of Figure 4 colludes and increases their balance after T n−k of user A's SPC, the smart contract will choose blocks from T n−k to T n−k−V uploaded by user A because the chains from the other users have invalid information between T n−k and T n−k+1 despite the highest round count.
Each user stores blocks of the last SPC cycle, [n − V, n − 1], at the current t = n to prove their balance; a user does not need to maintain older transactions than the n − V since it already confirms the state before n − V, and we can save local storage by removing obsolete transactions.

Concurrent Payments in Independent SPCs
The aforementioned sequential payments induce significant delays as the number of PSPs increases in the MPC. For example, users should wait for six SPC instances to pay again to a particular user in Figure 5. The delay of each SPC consists of the handshaking time for the SPC update and local chain propagation. Additionally, the verification time for the previous n blocks is required, but it is negligible compared to the communication delay. We denote the delay of each SPC as ∆ in this study.
To reduce such a turnaround delay, we form a group of independent SPCs for concurrent payments free from double spending. In Figure 4, payments on the SPC v AB and v CD can be conducted simultaneously because each SPC does not interfere with the other concerning the MPC state. The parallel SPCs can reduce the turnaround time from 6∆ to 3∆. Figure 6 illustrates an example of concurrent payments on independent SPCs of the six-party MPC. The figure shows that the MPC has the first several rounds with a maximum independent set of N/2 = 3 SPCs and k = 2 SPCs in the remaining rounds. There is an optimal SPC schedule only with the maximum independent set during five rounds for this example. However, finding the maximum independent sets is known as NP-hard. Therefore, we propose an iterative greedy approximation algorithm for a bounded degree graph (an approximation ratio of (deg(v ij ) + 2)/3, which finds a maximal independent set (MIS) iteratively by choosing a minimum degree SPC first at each step. Theorem 1. The number of MISs, M V , is bounded as proven in [49], and the number of MISs of size k, M k , is at most [50] k ≤ V/3 :  Table 3 shows the theoretical upper bound of the average SPCs and rounds for different sizes of the MPC derived by Equation (5). The average number of SPCs converges into the maximum independent set N/2 as the probability of finding larger k MISs increases according to the number of users. We implemented the SPC scheduling algorithm with the iterative MIS search described in Algorithm 3 and evaluated it with the same MPCs for comparison, as shown in Table 3; the algorithm can find the optimal schedule of N − 1 rounds for each MPC. The algorithm complexity can be reduced to O(VlogV) using the heap data structure and it needs to be executed only once at the beginning of MPC creation. Dequeue v ij ← root(Q) and Heapify(Q) 11: while Q is not empty do 12: if i, j / ∈ M r then 13: Enqueue i, j → M r

14:
Enqueue v ij → V r 15: else 16: Enqueue v ij → Q 17: end if 18: Dequeue v ij ← root(Q) and Heapify(Q) 19: end while 20: if Q is not empty then For this MPC with parallel SPCs, either full or partial synchronization can be considered, similar to the linear MPC model. The full synchronization keeps users updating an MPC state from the previous round. Meanwhile, partial synchronization has an update delay for the final status at the cost of reducing the communication overhead. For example, A can finalize the T 0 status at T 2 as it receives v DE from D at T 1 and v CF from F at T 2 in Figure 6. Although this synchronization delay increases by log-scale log V/2, owing to the accumulated blocks in the local chain, a user can suffer from communication overhead to trace the balance of a counterparty. For dispute resolution in the concurrent SPCs, the smart contract also receives all users' previous V blocks (almost [n − r, n − 1] rounds). It investigates each round for update as in Algorithm 2. In contrast to the linear MPC, each round is subjected to an MPC update only when all SPC transactions of a round are verified successfully.

Coalition Formation Game for MPC Creation
Although the MPC as a payment service consortium contributes to reducing the PSPs' collateral cost, the induced payment latency is considerable according to the MPC size; accordingly, the coalitional gain is not super-additive but limited by the latency cost. Therefore, we propose the MPC creation mechanism in the coalition formation game (CFG) framework, in which independent and rational PSPs form MPCs dynamically based on the distributed formation algorithm, which leads to a stable state for the MPC partitions.

CFG Model
The hedonic CFG is a coalitional game that satisfies the following two hedonic conditions. In this study, the PSPs can join and leave any MPC freely according to their preference, e.g., collateral cost reduction for the MPC coalition formation. Such a gain is decided only by the MPC in their participation.

Definition 1. (Hedonic Conditions): A CFG is classified as hedonic if (i) the payoff of any player depends solely on the coalition members to which the player belongs; (ii) the coalitions are partitioned according to players' preferences over coalitions.
For the mathematical model for MPC creation, we first define the notions of the coalition structure and transferable utility based on the CFG theory [51][52][53].

Definition 2.
A set of players in this CFG is a set of directional PCs in a PCN, L, which form a cooperative MPC coalition as a subset, S k ⊆ L. However, the actual players are PSPs, who determine coalitions for their directional PCs by executing the formation algorithm. Therefore, the disjoint coalitions constitute the coalition structure, Π = {S 1 , S 2 , ...S K }, L = ∪ K k=1 S k , which can be denoted by a set of V, {V 1 , V 2 , ..., V K }. The transferable utility value υ(S k ) of the coalition is determined solely by the coalition members in the characteristic form of this CFG, and it is fairly divided by SPCs.
To derive the aggregate utility of the coalition, we address the revenue and cost of the MPC as below.
• Revenue: sum of transaction fee over PBT flows served by an MPC coalition, υ r (S k ). • Cost: deposit sum of PSPs of an MPC, υ c (S k ). The collateral cost of individual PSPs is reduced by deposit sharing among multiple SPCs, which is limited by increasing payment delays from the SPC turnaround. Such an additional delay to the legacy PC, , ij ∈ S k , demands a larger deposit, thereby increasing the collateral cost. Furthermore, the delay cost will be −∞ if it exceeds the T exp , which can be a constraint for coalition formation. • Utility: with the above revenue and cost, the net payoff of the coalition formation can be υ(S k ) = υ r (S k ) − υ c (S k ).

Coalition Revenue Function
When a PBT flow, u, goes through an MPC, its ingress PSP i and egress PSP j receive an incentive for each transaction [34]. Therefore, the total transaction fee can be calculated by the PBT flow rate with the transaction fee rate, r .
where the x ij is the PBT rate of a PC (i, j).

Coalition Cost Function
If each PC needs deposit amount C ij to afford the given PBT demand, ∑ u x u ij ≤ C ij , the total required deposit of the MPC coalition S k can be as below: where α ij ∈ {0, 1} according to the existence of a PC ij, andS k is a subset of PCs with the maximum deposit for each PSP i, the maximum PBT rate deposit amount can cover all SPC transactions in its SPCs. The payment delay of the legacy PC, D PC ij , consists of transaction processing, propagation, and queuing. The transaction process delay is negligible compared to the two other factors, e.g., several micro-seconds. The message propagation delay, D u m,ij , depends on the distance and congestion in the underlying network, defined as a random variable of the exponential distribution in this study, P(D u m, as Ethernet based on carrier-sense multiple access with collision detection (CSMA/CD) has an access delay according to the binary back-off window [54] (i.e., the network delay can be modeled also by normal or Pareto distributions). Meanwhile, the queuing delay is critical according to bidirectional PBT flows modeled by M/M/1.
Although the queuing delay is theoretically infinite for ∑ u x u ji < ∑ u x u ij , the maximum delay is the lock time in the off-chain system as all transactions over T exp are canceled automatically. Furthermore, PSPs can cancel in-flight lock transactions using a rollback procedure in advance. For ∑ u x u ji = ∑ u x u ij , in which the same amount moves back and forth for bidirectional PBTs, the queuing delay of a PBT is limited by the PBT interval, x −1 ji . Moreover, the MPC delay D MPC ij is mainly caused by the queuing and SPC turnaround. The queuing delay of the MPC, D u q,ij , is determined by the balance of the aggregated flow rate. The egress aggregated PBT flow rate from a PSP i to any PSP j, λ ij can be written as below: where the maximum delay for SPC turnaround, Σ D = max ∆ ∑ N−1 r=0 ∆ r ij , depends on the transaction process and propagation delay of each SPC. Suppose that each PSP has multiple PCs outside of the MPC, ik ∈ L \ V, and asymmetric and bidirectional PBT flows x u ik and x u ki are passed through the MPC; the aggregated PBT flow from the PSP i to others j in the MPC, λ ij in Equation (9), is equivalent to ∑ k∈I \N ∑ u x u ki and µ ij is the same as ∑ k∈I \N ∑ u x u ik , the sum of all PBT flows toward the PSP i. Consequently, λ ij = µ ij for a PSP i as ∑ k∈I \N ∑ u x u ki = ∑ k∈I \N ∑ u x u ik is satisfied.

Property 2. The MPC queuing delay is limited by the SPC turnaround time if the MPC is balanced,
Once the deposit of a particular PSP is unbalanced due to a pair of asymmetric flows, x u ik and x û ki , it will be rebalanced by another pair of flows, x u ik and x u ki , within the Σ D because λ ij = µ ij is guaranteed. For example, if a flow x u ik depletes the balance of the PSP i at T 0 and a new payment, A i (t m ), arrives at the next SPC T 1 , the payment needs to wait for Σ D until the deposit of the PSP i can be C ij + A i (T 1 ) at T N , where C ij is the initial deposit of the PSP i. We need an effective SPC scheduling algorithm for balance stability to reduce deposit variance.
, where the C ij is the maximum initial deposit among coalitional PCs ij of the PSP i.
If a legacy PC ij needs a maximum C ij deposit for the highest PBT flow rate, the SPC ij requires an additional deposit C ij Σ D for queued transactions during the turnaround time. Accordingly, other SPCs are affordable, with less deposit for new and queued transactions than the maximum SPC.
The collateral cost for additional transaction delays due to the SPC turnaround time whereS k is defined in Equation (7) and all PSPs have equivalent PBT flows, λ ij = µ ij , within the MPC coalition, S k . Consequently, we define the MPC CFG cost function, υ c (S k ) = c (υ 1 c (S k ) + υ 2 c (S k )), with an interest rate, c , that is comparable with the transaction fee.

MPC Formation Algorithm
In this CFG, the PSPs constitute multiple independent and disjoint coalitions considering deposit gains from cooperation and additional costs from the MPC size. This partition problem for the coalition structure Π is known as NP-hard, as the number of the coalitions is the Bell number. Moreover, the PCN is a fully distributed system in which a PSP joins or leaves freely through the main blockchain. This study introduces a distributed algorithm using the switch operation based on preference order.
The preference order, i , provides each PSP with a strict rule of preference between two coalitions during dynamic coalition formation. For instance, the relation S 1 i S 2 indicates that a player i prefers to join the S 1 coalition rather than the other, Although revenue and cost are given to each directional PC, ij ∈ L, the bidirectional PCs, ij and ji, need to derive a common strategy for switching operations regardless of individual payoff. Otherwise, the individual payoff will be practically zero as the PC is not established. Therefore, the switch operation splits and merges two PCs ij and ji together between MPCs at each step. For simplicity of notation, we use i of i for an SPC i inV hereafter.
For the preference order of an SPC i, u i (S k ) is the sum of individual SPC payoff without coalition and the expected coalition gain that is calculated by dividing fairly the marginal utility of the coalition S k . Here, the fair division encourages a PSP with fewer PBT flows to join an MPC with many PBT flows.
where the i andĩ are an SPC ij, ji, respectively, and H i (k) is a history set that contains all previous coalitions that the SPC i joined across all past partitions, Π 0 , Π 1 , ...Π k .
In this study, we introduce two preference rules, Pareto and selfish order, for forming MPC coalitions. Utilitarian order, which considers social welfare altruistically, is inappropriate for PSPs to pursue their profits, i.e., payment fees and incentives for their deposits.
Definition 3. (Pareto order): Pareto order is one of the traditional preference relations for the CFG, which has strong restrictions, preventing damage for original and new coalitions, as in the following equation.
(Switch operation): A PSP {i} as a player leaves a coalition S k and joins another coalition S l according to the preference order, denoted as ϕ k,l (i) : S k \ {i}, S l ∪ {i}, which changes MPC coalition formation in a PCN from initial partition Π 0 , Π 1 , ..., Π n sequentially. The switching gain, g(ϕ k,l (i)), is an individual payoff increment that can vary according to the preference order.

Theorem 2.
(Nash-stable coalition): A coalition Π is Nash-stable if and only if no player individually improves its utility via the switch operation. g(ϕ k,l (i)) ≤ 0 for all S k , S l ∈ Π. The selfish and Pareto orders enable MPC coalitions to converge into the Nash-stable coalition partitions.
Proof. Suppose that a final partition Π f from finite iterations is not Nash-stable; any PSP can perform further switch operations for higher utility, which means that the Π f is not the final coalition. Accordingly, the final partition state will be stable. Moreover, the number of switching iterations is finite, less than several possible partitions, since a player switches only to a coalition that has not been visited before.
Algorithm 4 shows an MPC formation function for a PSP. The PSP starts with a singletone coalition and merges with another SPC based on preference until the Nash-stable coalition formation is established. The new MPC coalitions provide the maximum gain for each SPC in every iteration. Each SPC considers candidate MPC coalitions that have not been visited before and contain other SPCs of the same PSP to maximize their payoff. These partition updates continue until no SPC improves its payoff for further switching.
We show a simple MPC CFG in Figure 7 with PBT flows demanded as in Table 4. Because all PCs are noncooperative initially, some PCs having asymmetric flows need to set a circular flow and increase the deposit amount to avoid excessive queuing delays; for instance, the imbalance of the PC V 12 by AB and BA forces PSP 1 to find a circular flow toward PSP 2 and increase the deposit up to 100 tokens. Therefore, the final deposit is 100 tokens for each PC, and 300 tokens are necessary for each PSP. Alternatively, PSP B can reduce the flow BA rate to 50, which, however does not satisfy the user demand. Meanwhile, the MPC formation of PSPs 1-4 can support all flows with 100 + 100Σ D tokens.

Experimental Results
We generate multi-PBT flows in SNS-driven PCNs and build MPC formation using the proposed CFG algorithm. Random graphs such as a power-law clustering or partitioning model with a default of 20 PSPs are used for our experiment, as shown in Figure 8. The power-law clustering has a degree of a PSP as a vertex of 3 and clique probability of 0.7 as a default. The revenue and cost rate are configured as r = 0.2 and c = 0.1. Default E∆ is 0.1. User demand is given randomly by 50 or 100. We derive the average throughput with 100 randomly generated PCN topologies. First, we investigate the convergence of MPC partitioning via our distributed coalition algorithm with two preference rules. Figure 9 shows that the split and merge algorithm allows the MPCs to converge to a Nash-stable partition regarding the overall utility saturation of the PCN. For each Pareto and selfish preference order, the MPC partitions converge successfully to the equilibrium partition in very limited switch operations, 75 and 30, respectively. The selfish order constitutes an aggressive MPC, as Figure 9a shows a drastic decrement in MPCs compared to the Pareto in Figure 9b. The overall utility of the Pareto order increases monotonically. In contrast, the selfish order shows variations in several iterations because the Pareto rule prevents the payoff loss of MPCs caused by new partitions. For the Pareto test, we configure c = 0.2, the same as r , for an SPC to leave an MPC without harming the payoff of other members.  Figure 10a shows the average number of MPCs with varying PCN sizes regarding the number of PSPs where the selfish order was applied. The average number of MPCs almost linearly increases with more PSPs, but each size is at saturated around 8 as the degree of each PSP is limited, as in the graph topology. Figure 10b shows that the MPC formation is rather affected by the SPC turnaround delay cost, E∆. The number of MPCs increases with the higher E∆ values; the increment is notably between 0. 3   In addition to the MPC delay, E∆, collateral cost rate c is critical for MPC formation at a given revenue rate r = 0.5, as in Figure 11. Figure 11a shows the average payoff of each MPC with different c , which decreases exponentially with the increasing delay cost and is saturated between 0.15 and 0.2 of E∆ since there is no major change in partitions. The average utility of an individual MPC is higher with a lower cost rate c -for instance, 100 vs. 400 for c =0.5 and 0.1, respectively, at E∆ = 0.05.
Contrarily, the total marginal payoff of MPCs as the sum of all coalitional gains, ∑ k υ(S k ) − ∑ ij υ({(i, j)}), is higher with the cost rate c = 0.5 than others, owing to more deposit reuse. For instance, the marginal gain increases from 500 to 2500 with c =0.1 and 0.5, respectively, in Figure 11b when E∆ is 0.01. However, the E∆ limits such a coalition gain. Figure 11c shows the average MPC ratio (i.e., number of MPCs/number of initial partitions) increasing with higher cost rates, discouraging PSPs from joining the MPCs. The higher collateral cost rate aggravates the coalition gain and the turnaround delay. Accordingly, the higher c generates more MPCs with small sizes (the minimum MPC size is 2 for a single SPC). For instance, c = 0.1 merges the initial coalitions into 20% of them, while c = 0.5 achieves only 30% in the case of E∆ = 0.1. Moreover, the number of final partitions increases as the MPC delay cost E∆ becomes significant. In Figure 11d, accordingly, each MPC size decreases with the increasing delay cost, especially for the higher cost rate c . The MPC ratio and size are comparable between E∆ = 0.15 and 0.2 because the coalitional payoff is limited.  Figure 12a compares the marginal payoff when the degree of a PSP as several PCs is 3 or 4. We use the SPC delay E∆ = 0.05 to reveal the impact of the degree of a PSP in the power-law cluster PCNs. The total marginal payoff increases as more PSPs participate in the coalitional game and form more MPCs, as shown in Figure 10. The result shows that PSPs with PCs probably have more opportunities to form MPCs and gain payoff. The MPC ratio with the higher degree, 4, is slightly lower than the others because PSPs can be easily merged with more PCs, as in Figure 12b. Meanwhile, the MPC ratio is almost consistent with the number of PSPs. Figure 12c describes the MPC formation performance in the two different PCN topologies shown in Figure 8. More MPCs are established in the power-law cluster graphs rather than the ring of cliques, which has MPCs that are equal to the cliques. For instance, the 40 PSP case has 10 cliques and 9 interconnecting PCs, constituting around 19 MPCs. In the random PSP-clustered network, PC existence between two PSPs increases the probability of forming MPCs, as shown in Figure 12d. The MPC ratio decreases monotonically with higher PC connectivity probability from 0.5 and 0.7 to 0.9. Moreover, a higher degree of PSP among 3, 5, and 9 helps to build larger MPCs and reduce the MPC ratio.
Asymmetric PBT flows of user demands also affect the MPC formation because the revenue of the MPC is proportional to the PBT flow rate. Figure 13 shows the relation of MPC formation and user demand, where we apply E∆ = 0.01 to reduce the MPC overhead and highlight the impact of the user demand. Figure 13a shows that the MPC ratio decreases as the PSPs form larger coalitions for more revenue. In Figure 13b, the total marginal payoff from MPCs increases with more user demand. Consequently, more PBT flows increase the MPC utility and form a larger MPC in a profitable situation with a low MPC delay cost.

Conclusions
This study introduces the MPC scheme based on the public blockchain system with smart contract algorithms for channel management, which provides a secure PC among multiple participants with a single deposit from each PSP. This proposed idea enables users to reduce the collateral cost for multiple separate PCs for other users and also the risk of channel depletion due to asymmetric PBT flows.
Furthermore, we propose a distributed MPC formation algorithm for each PSP, adopting a CFG framework. This is the first study to propose a formation algorithm for MPC creation. The MPCs are established by consecutive switching operations considering the marginal utility between the payoff from the shared deposit and the delay cost induced by SPC turns.
Experimental results show that the proposed algorithm successfully establishes MPC coalitions with marginal gains. Their sizes depend on the SPC turnaround delay and collateral cost, rather than the PCN size and degree of SPCs. However, marginal utility by the MPC formation increases with a larger number of PSPs, transactions, and connectivity among PSPs.
In this study, we demonstrate theoretically the feasibility of the MPC concept and its formation algorithm based on several network models. Therefore, we will evaluate our system using an MPC simulator implemented by NS-3 for a real network environment. In addition, we will conduct further study to reduce the SPC turnaround time for a larger MPC and more efficient scheduling algorithm of SPCs, rather than the round robin that we now use.